package com.dodock.banglapapers.server;

import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.dodock.banglapapers.server.generator.DDNGetNewsDetailGenerator;

@SuppressWarnings("serial")
public class DDNGetNewsDetail extends HttpServlet {
	
	@Override
	protected void doGet(HttpServletRequest req, HttpServletResponse resp){
		resp.setContentType("application/json");
		resp.setCharacterEncoding("UTF-8");
		DDNGetNewsDetailGenerator gen = new DDNGetNewsDetailGenerator(req.getParameter("id"), req.getParameter("newsid"));
		try {
			resp.getWriter().write(gen.Generate());
		} catch (Exception e) {
			e.printStackTrace();
		
		}
	}
}
	
